package name.wilbur.course.db.bigone.model;
/**
 * @author wilbur
 */
public class Occupation extends BaseDBModel {
	private String occupationName;
	private String occupationDescription;
	
	public Occupation() {
	}

	public Occupation(String occupationName, String occupationDescription) {
		super();
		this.occupationName = occupationName;
		this.occupationDescription = occupationDescription;
	}

	public String getOccupationName() {
		return occupationName;
	}

	public void setOccupationName(String occupationName) {
		this.occupationName = occupationName;
	}

	public String getOccupationDescription() {
		return occupationDescription;
	}

	public void setOccupationDescription(String occupationDescription) {
		this.occupationDescription = occupationDescription;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = super.hashCode();
		result = prime
				* result
				+ ((occupationDescription == null) ? 0 : occupationDescription
						.hashCode());
		result = prime * result
				+ ((occupationName == null) ? 0 : occupationName.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (!super.equals(obj))
			return false;
		if (getClass() != obj.getClass())
			return false;
		Occupation other = (Occupation) obj;
		if (occupationDescription == null) {
			if (other.occupationDescription != null)
				return false;
		} else if (!occupationDescription.equals(other.occupationDescription))
			return false;
		if (occupationName == null) {
			if (other.occupationName != null)
				return false;
		} else if (!occupationName.equals(other.occupationName))
			return false;
		return true;
	}
	
}
